# 序列的切片实践
# 由指定字符串输出"I am learning python"
my_str = "!!!dlrow nohtyp gninrael ma I olleH"
index_begin = my_str.index('I')
index_end = my_str.index(' ')
new_my_str = my_str[index_begin:index_end:-1]
print(new_my_str)